<%@page import="com.entity.ProType"%>
<%@page import="com.biz.ProTypeBizImpl"%>
<%@page import="com.entity.UserInfo"%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@include file="/admin/do/checklogin.jsp" %>
<%
	request.setCharacterEncoding("utf-8");
	String tname=request.getParameter("tname");
	String uname=((UserInfo)session.getAttribute("loger")).getUname();
	
	ProType pt=new ProType();
	pt.setTname(tname);
	pt.setUname(uname);
	if(new ProTypeBizImpl().addProType(pt)>0){
%>
	<script>location='../showProType.jsp';</script>
<%
	}else{
%>
	<script>alert("添加失败");location='../addProType.jsp';</script>
<%
	}
%>

